package com.xiaoma.test;

/**
 * @author maj
 * @ClassName YunSuan
 * @Description
 * @date 2020-08-05 15:33
 */
public class YunSuan {

  public static void main(String[] args) {

    int[] ints=new int[5000];
    ints[ints.length-1]=1;
    int n=7665;

    for(int i=1;i<=n;i++) {
      ints=yunSuan(ints, i);

    }
    for(int i=0;i<ints.length;i++) {
      System.out.print(ints[i]);
    }


  }


  public static int[] yunSuan(int[] ints,int num) {

    for(int i=0;i<ints.length;i++) {

      ints[i] = ints[i]* num;

    }

    for(int i=ints.length-1;i>0;i--) {
      ints[i-1]=ints[i-1]+ints[i]/10;
      ints[i]=ints[i]%10;

    }

    return ints;
  }
}
